#!/bin/sh

# 复制项目的文件到对应docker路径，便于一键生成镜像。
usage() {
	echo "Usage: sh copy.sh"
	exit 1
}


# copy sql
echo "begin copy sql "
cp ../sql/ry_20231130.sql ./mysql/db
cp ../sql/ry_config_20231204.sql ./mysql/db

# copy html
echo "begin copy html "
cp -r ../IntelligentCommunity-ui/dist/** ./nginx/html/dist


# copy jar
echo "begin copy IntelligentCommunity-gateway "
cp ../IntelligentCommunity-gateway/target/IntelligentCommunity-gateway.jar ./IntelligentCommunity/gateway/jar

echo "begin copy IntelligentCommunity-auth "
cp ../IntelligentCommunity-auth/target/IntelligentCommunity-auth.jar ./IntelligentCommunity/auth/jar

echo "begin copy IntelligentCommunity-visual "
cp ../IntelligentCommunity-visual/IntelligentCommunity-monitor/target/IntelligentCommunity-visual-monitor.jar  ./IntelligentCommunity/visual/monitor/jar

echo "begin copy IntelligentCommunity-modules-system "
cp ../IntelligentCommunity-modules/IntelligentCommunity-system/target/IntelligentCommunity-modules-system.jar ./IntelligentCommunity/modules/system/jar

echo "begin copy IntelligentCommunity-file "
cp ../IntelligentCommunity-modules/IntelligentCommunity-file/target/IntelligentCommunity-file.jar ./IntelligentCommunity/modules/file/jar

echo "begin copy IntelligentCommunity-modules-job "
cp ../IntelligentCommunity-modules/IntelligentCommunity-job/target/IntelligentCommunity-modules-job.jar ./IntelligentCommunity/modules/job/jar

echo "begin copy IntelligentCommunity-gen "
cp ../IntelligentCommunity-modules/IntelligentCommunity-gen/target/IntelligentCommunity-gen.jar ./IntelligentCommunity/modules/gen/jar

